import { setCookies, getCookies } from '@/utils/auth'
const state = {
  systemConfig: getCookies('SYSTEMCONFIG'), //是否有权限
}
const mutations = {
  SET_SYSTEMCONFIG: (state, data) => {
    state.config = data
    setCookies('SYSTEMCONFIG', data)
  }
}
const actions = {
  getSystemConfig(store, system) {
    const { commit } = store
    console.log('传值', system)
    commit('SET_SYSTEMCONFIG', system)
  }
}
export default {
  namespaced: true,
  state,
  mutations,
  actions
}